﻿<!DOCTYPE HTML>
<html>
{include file="public:header_css"}

<body>

<nav class="breadcrumb">
	<i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> 门店管理 <span class="c-gray en">&gt;</span> 绑定管理员
	<a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a>
</nav>

<div class="page-container">

	<div class="form form-horizontal">
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">门店管理员：</label>
			<div class="formControls col-xs-8 col-sm-9" style="margin-bottom:30px;">
				<div id="admin"></div>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">门店签到员：</label>
			<div class="formControls col-xs-8 col-sm-9" style="margin-bottom:30px;">
				<div id="sign_in"></div>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">绑定教师：</label>
			<div class="formControls col-xs-8 col-sm-9" style="margin-bottom:30px;">
				<div id="teacher"></div>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">绑定家长：</label>
			<div class="formControls col-xs-8 col-sm-9" style="margin-bottom:30px;">
				<div id="parent"></div>
			</div>
		</div>
		<div class="row cl">
			<div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <a class="btn btn-warning radius" href="{:url('index')}">&nbsp;&nbsp;取消&nbsp;&nbsp;</a>
			</div>
		</div>
	</div>

</div>
{include file="public:footer_js"}

<script type="text/javascript" src="__STATIC__/qrcode/qrcode.min.js"></script>

<script type="text/javascript">

	var store_id = '{$store_id}';
	if(store_id <=0){
        layer.msg('未选择门店!',{icon:7,time:2000});
        setTimeout(
            // 跳转至管理后台首页
            function(){
                location.replace("{:url('index')}");
            },
            3000
        );
	}

	// 生成二维码
    function makeCode (url,dom) {
        var qrcode = new QRCode(document.getElementById(dom), {
            width : 150,
            height : 150
        });
        qrcode.makeCode(url);
    }

    // 生成对应的二维码
	makeCode("{$url_arr[0]}",'admin');
    makeCode("{$url_arr[1]}",'sign_in');
    makeCode("{$url_arr[2]}",'teacher');
    makeCode("{$url_arr[3]}",'parent');

</script>

</body>
</html>